home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
World of Video
/
World of Video.iso
/
gfxprograms
/
3dprograms
/
rayshade-4.0
/
rayfiles
/
rsdefs
/
objects
/
prisms.rh
< prev
next >
Wrap
Text File
|
1995-02-13
|
2KB
|
51 lines
/************************************************************************
*
* prisms.rh
*
* This is an #include file for the Rayshade Standard Header
* Files. It defines the prism superprimitives in the package.
*
* Please do not edit this file, or any of the other files in
* this package! Make additions to these in your own separate
* file. If you think you have something that should be added
* permanently, please send it to Larry Coffin and/or David
* DeBry (email addresses listed below). If we include it in
* the next release, we'll put your name in the contributor's
* list.
*
* Contributors (in alphabetical order):
* Larry Coffin <lcoffin@clciris.chem.umr.edu>
* David DeBry <ddebry@dsd.es.com>
*/
#ifndef RSHF_PRISMS
#define RSHF_PRISMS
#define RSPquadprism(prefix,s,a,b,c,x,y,z) \
prefix list \
poly s (a) (b) (c) (x) (b) (c) (x) (y) (c) (a) (y) (c) \
poly s (a) (b) (c) (a) (y) (c) (a) (y) (z) (a) (b) (z) \
poly s (a) (b) (z) (x) (b) (z) (x) (y) (z) (a) (y) (z) \
poly s (x) (b) (z) (x) (b) (c) (x) (y) (c) (x) (y) (z) \
end
/*************************************************************************
*
* NOTE: RSPtriprism() will give a valid CSG solid only if the
* points (x1,z1), (x2,z2), (x3,z3) are given in clockwise order
* when viewed from the along (-y) axis and "y" is not negative.
*
*/
#define RSPtriprism(prefix,s,x1,z1,x2,z2,x3,z3,y) \
prefix list \
poly s (x1) 0 (z1) (x2) 0 (z2) (x2) (y) (z2) (x1) (y) (z1) \
poly s (x2) 0 (z2) (x3) 0 (z3) (x3) (y) (z3) (x2) (y) (z2) \
poly s (x3) 0 (z3) (x1) 0 (z1) (x1) (y) (z1) (x3) (y) (z3) \
triangle s (x1) (y) (z1) (x2) (y) (z2) (x3) (y) (z3) \
triangle s (x1) 0 (z1) (x3) 0 (z3) (x2) 0 (z2) \
end
#endif /* ifndef RSHF_PRISMS */